<?php $id = getId(); ?>
<div class="x-list-title">
<table width="100%" border="0" height="100%">
<tr><td align="left">
	<h2>Danh bạ nội bộ</h2>
</td><td align="right">
<div class="x-list-options">
	<!--<div class="x-options-container">
		<a class="x-button">Tác vụ khác <span>&#9660;</span></a>
		<div class="x-options">
			<a class="x-options-item" onclick="module_delete('<?php _baseUrl()?>/Contact/Publish/Deleteallperson','f<?php _e($id);?>',this)">Xóa đã chọn</a>
		</div>
	</div>-->	
</div>
</td></tr></table>	
</div>
<?php
$vars = $this->get('vars');
$link = '#'.$this->module."/".$this->controller."/".$this->action;
?>
<form action="" method="post" id="f<?php _e($id);?>">
<table width="100%" class="x-list" cellpadding="0" cellspacing="0">
<tr>
	<th width="25" align="center">
		TT
	</th>
	<th align="center" width="140">
		<?php show_order_link('Họ tên','title',$link,$vars) ;?>
	</th>
	<th align="center" width="140">
		<?php show_order_link('Phòng ban','department_title',$link,$vars) ;?>
	</th>
	<th align="center">
		<?php show_order_link('Địa chỉ','address',$link,$vars) ;?>
	</th>
	<th align="center" width="100">
		<?php show_order_link('Phone','phone',$link,$vars) ;?>
	</th>
	<th align="center" width="160">
		<?php show_order_link('Email','email',$link,$vars) ;?>
	</th>
	<th align="center" width="50" colspan="2">Tác vụ</th>
	<th align="center" width="25">
		<!--<div class="x-check-container">
			<div class="x-check">
			<input type="checkbox" class="x-checkbox x-checkall"/>
			</div>
			<div class="x-check-options">
				<a class="x-check-item check-all">Chọn tất cả</a>
				<a class="x-check-item uncheck-all">Bỏ chọn</a>
			</div>
		</div>-->
	</th>
</tr>
<?php if( count($this->get("posts")) > 0 ): ?>
<?php foreach( $this->get("posts") as $k => $a ): ?>
	<tr>
	<td align="center">
		<?php _e($k+1);?>
	</td>
	<td>
		<a href="#Contact/Personnel/View?ID=<?php _e($a['ID']);?>">
			<?php _e(short_title($a['name'],50));?>
		</a>
	</td>
	<td>
		<?php _e( $a['department_title'] );?>
	</td>	
	<td>
		<?php _e( short_title($a['address'],40) )?>
	</td>
	<td align="center">
		<?php _e( $a['phone'] )?>
	</td>

	<td>
		<?php _e( $a['email'] )?>
	</td>
	<td align="center" width="25">
		<a class="x-nodelete"></a>
	</td>
	<td align="center" width="25">
		<a class="x-noedit"></a>
	</td>

	<td align="center">
		<input type="checkbox" disabled/>
	</td>
	</tr>
	<?php endforeach;?>
	<tr>
		<td colspan="9" class="page">
		<div class="x-page">
			<?php $this->e("page");?>
		</div>		
		</td>
	</tr>
	<?php else:?>
	<tr>
		<td colspan="9" class="page">
			<div class="x-page">Không có bản ghi nào được tìm thấy</div>
		</td>
	</tr>
	<?php endif;?>
</table><br/><br/>
</form>